<span ng-if="clientslist">
	<h3><small><p class="text-right">Connected clients: {{clients.length}}</p></small></h3>

	<div class="table-responsive" ng-if="clients.length >0">
		<table class="table table-striped table-hover table-condensed table-href">
		<thead>
			<tr>
				<th>Client Endpoint</th>
				<th>Registration ID</th>
				<th>Registration Date</th>
				<th>Last Update</th>
				<th></th>
				<th></th>
				<th></th>
			</tr>
		</thead>
		<tbody>
			<tr ng-click="showClient(client)" ng-repeat="client in clients">
				<td><a ng-href="#/clients/{{client.endpoint}}"> <strong>{{client.endpoint}}</strong></a> </td>
				<td>{{client.registrationId}}</td>
				<td>{{client.registrationDate | date:'medium'}}</td>
				<td>{{client.lastUpdate | date:'medium'}}</td>
				<td><i class="glyphicon glyphicon-info-sign" tooltip-html-unsafe="{{clientTooltip(client)}}"></i></td>
				<td><span class="glyphicon glyphicon-lock"
                          ng-style="{'visibility': client.secure ? 'visible': 'hidden'}"
                          tooltip-html-unsafe="Communication over DTLS"></span></td>
				<td><span class="glyphicon glyphicon-log-out"
                          ng-style="{'visibility': client.sleeping ? 'visible': 'hidden'}"
                          tooltip-html-unsafe="Device using queue mode is absent"></span></td>
			</tr>
		</tbody>
		</table>
	</div>
</span>

<span ng-if="error">
	<div class="alert alert-danger">{{error}}</div>
</span>
